﻿using Abp.Dependency;
using Microsoft.Extensions.Configuration;
using Sunlit.Business.Configuration;
using System;
using System.Collections.Generic;
using System.Text;

namespace Sunlit.Business.Net.Sms
{
    public class AliyunSmsSenderConfiguration : ITransientDependency
    {
        private readonly IConfigurationRoot _appConfiguration;
        public AliyunSmsSenderConfiguration(IAppConfigurationAccessor configurationAccessor)
        {
            _appConfiguration = configurationAccessor.Configuration;
        }
        public string AppKey => _appConfiguration["SmsConfiguration:AliSms:AppKey"];
        public string Secret => _appConfiguration["SmsConfiguration:AliSms:Secret"];
        /// <summary>
        /// 签名
        /// </summary>
        public string SignName => _appConfiguration["SmsConfiguration:AliSms:SignName"];
        /// <summary>
        /// 注册验证码模板代码
        /// </summary>
        public string RegisterTemplateCode => _appConfiguration["SmsConfiguration:AliSms:RegisterTemplateCode"];
        /// <summary>
        /// 重置密码验证码模板代码
        /// </summary>
        public string ResetPasswordTemplateCode => _appConfiguration["SmsConfiguration:AliSms:ResetPasswordTemplateCode"];
        /// <summary>
        /// 登录验证码模板代码
        /// </summary>
        public string LoginTemplateCode => _appConfiguration["SmsConfiguration:AliSms:LoginTemplateCode"];
    }
}
